package com.example.consumer.controller;

import com.example.consumer.service.LimitService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 限流
 */
@RestController
public class LimitController {
    @Autowired
    private LimitService limitService;

    @GetMapping("/test-a")
    public String testA() {
        limitService.common();
        return "test-a";
    }

    @GetMapping("/test-b")
    public String testB() {
        limitService.common();
        return "test-b";
    }
}
